﻿using System;
using System.Collections.Generic;
using System.Windows.Forms;
using System.ServiceProcess;

using ReportLostCard.Source;
using FoxConn.Lib.Dbo;
using FoxConn.Lib.Winform;

namespace ReportLostCard
{
    static class Program
    {
        /// <summary>
        /// 应用程序的主入口点。
        /// </summary>
        [STAThread]
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            XMLutil xmlUtil = new XMLutil();
            Config.DEBUG = xmlUtil.GetXMLParameter("Debug");

            if (Config.DEBUG.Equals("0"))
            {
                ServiceBase[] serviceBase = new ServiceBase[] {new ReportService()};
                ServiceBase.Run(serviceBase);
            }
            else
            {
                MainFunction mf = new MainFunction();
                mf.run();
            }
        }
    }
}